<template>
  <div class="app-container">
    <!-- 放一个Header -->
    <mt-header fixed title="Cyan项目">
      <span  slot="left">
        <mt-button icon="back">返回</mt-button>
      </span>
    </mt-header>

    <!--路由的容器  -->
    <transition>
      <router-view></router-view>
    
    </transition>

    <!-- tabbar区域 -->
    <nav class="mui-bar mui-bar-tab">
      <routerLink class="mui-tab-item " to="/home">
        <span class="mui-icon mui-icon-home"></span>
        <span class="mui-tab-label">首页</span>
      </routerLink>
      <routerLink class="mui-tab-item" to="/member">
        <span class="mui-icon mui-icon-contact">
        </span>
        <span class="mui-tab-label">会员</span>
      </RouterLink>
      <routerLink class="mui-tab-item" to="/shop">
        <span class="mui-icon mui-icon-extra mui-icon-extra-cart">
          <span class="mui-badge">9</span>

        </span>
        <span class="mui-tab-label">购物车</span>
      </RouterLink>
      <routerLink class="mui-tab-item" to="/search">
        <span class="mui-icon mui-icon-search"></span>
        <span class="mui-tab-label">搜索</span>
      </routerLink>
    </nav>
  </div>
</template>

<script>
export default {};
</script>

<style  scoped>
/*  私有的，不会成为全局样式，也不会应用给子组件 */
.app-container {
  padding-top: 40px;
  padding-bottom: 50px;
  overflow: hidden;
}


/* 动画效果相关的类样式 */
.v-enter{
    /* position:unset; */
    opacity: 0;
    transform: translateX(100%);
}
.v-leave-to{
  position: absolute;
  opacity: 0;
  transform: translateX(-100%);
}

.v-enter-active,
.v-leave-active{
  transition: 0.4s;
}

.mint-header{
  z-index: 99;
}
</style>